/**
 * Created by lenovo on 19/4/19 019.
 */
/*alert("我的第二个javescript网页");*/
/*console.log("你好");*/


/*
alert(230+220);*/

/*
alert(2 * 3 + 25/5);*/

/*alert(2 *(25+4) - 2);*/

/*
alert(22 == 22);*/

//alert(22 == 33);

/*
/!*中文 字母 字符串*!/
alert("holle");
alert('holle');

/!*用数字：用引号包起来，字符串，不用引号包起来就是纯数字*!/
alert("123");
alert('123');
alert(123);

/!*已运算的形式呈现的结果*!/
alert(123 + 123);
/!*以拼接的形式呈现*!/
alert("123" + "123");*/

/*console.log(123 == 123);
console.log("123" == "123");
console.log("10" == 10);
console.log(10 === "10");
console.log(10 > 10);
console.log(10 > 9);*/

/*
alert('120' + '130');
alert('220 + 230 =' +220 +230);
alert('220 + 230 =' +(220 + 230));

*/

/*
if(22 < 33){
    alert(true );
}else{
    alert(false);
}*/

/*
/!*定义变量*!/
var num1 = 22;
var num2 = 33;
var temp = num1;

alert(num1);
alert(num2);

num1 = num2;
num2 = temp;


console.log(num1);
console.log(num2);
*/
/*函数返回结果*/
/*
prompt();*/

/*
if (prompt("请输入内容") == "admin"){
    alert("你好，管理员");
}else{
    alert("你好，用户");
}*/


/*时间*/

/*
var time = new Date();
var h = time.getHours();

if ( h < 12){
    alert("上午好");
}else if( 19 > h ){
    alert("下午好");
}else{
    alert("晚上好");
}*/


/*
function sum(a,b){
    var c = a + b;
    return c;
}

alert(sum(10,20));
alert(sum(20,30));

*/


/*
function sum(a,b){
    alert(a * b);
}

sum (200,200);
sum (250,350);

*/

/*var header = document.querySelector("header");
console.log(header);
header.innerHTML = "1";

var banner = document.querySelector(".banner");
console.log(banner);
banner.innerHTML = "2";

var footer = document.querySelector("#footer");
console.log(footer);
footer.innerHTML = "3";*/


/*
var stu = {};
stu.name = "小明";
stu.age = "18";
stu.es = "男";

stu.say = function(){
    return "我是"+this.name+",性别"+this.es+",我今年"+this.age+"岁了";
};

console.log(stu.name);
console.log(stu.say());

*/

function color(bgcolor){
    document.body.style.backgroundColor = bgcolor;
}

function div(c){
    color(c.value);
}












